<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>初见VUE</title>
  <script src="../js/vue.js"></script>
</head>
<body>
  <div id="app">
    <div :style="{ fontSize:'30px', color: 'teal'}">hello vue</div>
    <div :style="style1">hello vue</div>
    <div :style="[ style1, style2]">hello vue</div>
  </div>
  <script>
    let vm = new Vue({
      el: '#app',
      data: {
        style1: {
          fontSize: '30px',
          color: 'orange',
          marginTop: '10px'
        },
        style2: {
          color: 'red',
          backgroundColor: 'pink'
        }
      },
      
    })
  </script>
</body>
</html>